#ifndef _IOT_GPS_H_
#define _IOT_GPS_H_

typedef enum
{
    IOT_GPS_WORK_MODE_RAW_DATA = 0,         /*Just need raw data*/
    IOT_GPS_WORK_MODE_LOCATION,             /*Just need location*/
    IOT_GPS_WORK_MODE_LOCATION_WITH_QOP     /*Need AGPS data with Qop*/
} iot_E_GpsWorkMode;

typedef void (* iot_gpsDataHdler)(iot_uint8_t * data, iot_uint16_t len);

extern iot_bool_t iot_initGPS(iot_E_GpsWorkMode workMode);
extern iot_bool_t iot_openGPS();
extern iot_bool_t iot_closeGPS();
extern iot_bool_t iot_setGpsRefLocation(iot_float32_t lat, iot_float32_t lng);
extern iot_bool_t iot_isGpsTimeSyncOK();
extern iot_bool_t iot_isGpsEpoSyncOK();
extern void iot_setGpsDataHdler(iot_gpsDataHdler gpsDataHandleFunc);
extern iot_int32_t iot_writeGpsUart(iot_uint8_t * buffer);

#endif
